<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html>
<html lang="en">
<?php $title = '修改密码'; ?>
<head>
	<meta charset="UTF-8">
	<title><?php echo ($title); ?></title>
    <meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=0">
	<link rel="stylesheet" href="/Application/Home/View//Public/static/css/weui.min.css"/>
    <link rel="stylesheet" href="/Application/Home/View//Public/static/css/jquery-weui.min.css"/>
    <link rel="stylesheet" href="/Application/Home/View//Public/static/css/custom.css"/>
    <style type="text/css">
		body{
			background:#f1f1f1;
			color:#a3a3a3;
			font-family:"Microsoft YaHei";
		}
		.bd{
			padding:20px;
		}
        li{list-style: none;}
		p{
			font-size: 13px;
		}
		.weui-cell_select-before .weui-cell__hd:before{
			border-width: 0px 2px 2px 0;
			margin-top: -6px;
		}
		.weui-cell_select-before .weui-cell__hd:after{border:none;}
        .sstmb {
            padding-bottom: 60px;
        }
        .foot-ul{
			text-align:center;
			margin-top: 1rem;
			padding:10px;
			background: #22a9fe;
			opacity: 0.9;
		}
		.foot-ul a{
			color: #fff;
		}
		.foot-ul a img{
			max-width: 24px;
		}
		.pinglun{
			padding: 0 2px;
			background: #ff5959;
			border-radius: 50px;
			color: #fff;
			position: absolute;
			top:-6px;
			left:73px;
			font-size: 13px;
		}
		
		
		.weui-cell__bd p{
		color:#6b6969;
		}
        
	</style>
</head>

<body ontouchstart>

<style type="text/css">
		body{
			background:#f1f1f1;
			color:#3d3d3d;
			font-family:"Microsoft YaHei";
		}
		.bd{
			padding:20px 0;
		}
		.weui-cell_select-before .weui-cell__hd:before{
			border-width: 0px 2px 2px 0;
			margin-top: -6px;
		}
		.weui-cell_select-before .weui-cell__hd:after{border:none;}
		.weui-cell{display:-webkit-box}
		<!-- .weui-cell__bd>p{min-width:100px;} -->
	</style>

    <div class="container js_container">

    </div>
<div class="page">
    <div class="bd">
    <div class="weui-cells">
		<div style="height:2.2rem;" class="weui-cell weui-cell_select weui-cell_select-before">
	  <div class="weui_cell_hd"><img src="/Application/Home/View//Public/static/images/user.png" alt="" style="width:17px;margin-left:20px;display:block"></div>
	  <div  class="weui-cell__bd">
              <p >账户</p>
            </div>
        <div class="weui-cell__bd">
          <input  class="weui-input" type="number" pattern="[0-9]*" placeholder="请输入手机号/账号" value='<?php echo (session('phone')); ?>' readonly>
        </div>
      </div>
	  
      <div style="height:2.2rem;" class="weui-cell weui-cell_select weui-cell_select-before">
	  <div class="weui_cell_hd"><img src="/Application/Home/View//Public/static/images/pass.png" alt="" style="width:17px;margin-left:20px;display:block"></div>
	   <div  class="weui-cell__bd">
              <p >密码</p>
            </div>
        <div class="weui-cell__bd">
          <input  class="weui-input" type="number" pattern="[0-9]*" placeholder="请输入密码" id='pwd'>
        </div>
      </div>
	  <!-- <div style="height:2.2rem;" class="weui-cell weui-cell_select weui-cell_select-before"> -->
	  <!-- <div class="weui_cell_hd"><img src="/Application/Home/View//Public/static/images/pass.png" alt="" style="width:17px;margin-left:20px;display:block"></div> -->
	   <!-- <div  class="weui-cell__bd"> -->
              <!-- <p >确认密码</p> -->
            <!-- </div> -->
        <!-- <div class="weui-cell__bd"> -->
          <!-- <input  class="weui-input" type="number" pattern="[0-9]*" placeholder="请输入密码"> -->
        <!-- </div> -->
      <!-- </div> -->
  </div>

        <div style="margin:2rem auto;width:12rem;border-radius:20px;" class='demos-content-padded'>
      <a style="background:#22a9fe;" href="javascript:mod();" class="weui-btn weui-btn_primary">修改密码</a>
	  <!-- <p> -->
        <!-- <a href="javascript:;" class="weui-btn weui-btn_primary weui-btn_loading">正在加载...</a> -->
      <!-- </p> -->
		</div>
    </div>
</div>
    <script src="/Application/Home/View//Public/static/js/jquery-2.1.4.js"></script>
    <script src="/Application/Home/View//Public/static/js/jquery-weui.min.js"></script>
    <script src="/Application/Home/View//Public/static/js/fastclick.js"></script>
    <script src="/Application/Home/View//Public/static/layer/layer.js"></script>
    <script src="/Application/Home/View//Public/static/js/jquery.form.js"></script>
    <script>
      $(function() {
        FastClick.attach(document.body);
      });
    </script>
</body>
</html>

<script>
  function mod(){
     if($("#pwd").val() == ''){
        $.alert('请输入密码!');
     }else{
        $.ajax({
           url:'<?php echo U("index/mod_pwd");?>',
           data:{'pwd':$("#pwd").val()},
           type:"POST",
           success:function(data){
               if(data == 1){
                  $.alert('修改成功!', function(){
                     location.href='<?php echo U("index/more");?>';
                  });
               }else{
                  $.alert('修改失败，请稍后重试!');
               }
           }
        })
     }
  
 }
</script>